package com.homegoods.shoppingcar.item;

import android.content.Intent;

import com.alibaba.android.arouter.launcher.ARouter;
import com.homegoods.aroutercomment.ARouterPath;
import com.homegoods.shoppingcar.R;
import com.kedll.library.mvp.BaseItem;

/**
 * @author QiQi
 * @ClassName: ShoppingCarEmptyItem
 * @date 2018/10/11
 * @description
 */
public class ShoppingCarEmptyItem extends BaseItem {
    public ShoppingCarEmptyItem() {
        super(null);
        setOnClickListener(v -> ARouter.getInstance()
                .build(ARouterPath.PATH_MAIN_HOME)
                .withFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP|Intent.FLAG_ACTIVITY_SINGLE_TOP|Intent.FLAG_ACTIVITY_NEW_TASK)
                .navigation());
    }

    @Override
    public int getLayout() {
        return R.layout.shopping_empty;
    }
}
